<div class="sale" ng-controller="sale">
	<button type="button" ng-class="startBtn" ng-click="startSale()" ng-disabled="start === 'notShade'">{{startBtnState}}</button>
	<div>
		<div ng-class="start"></div>
		<section class="add">
			<form class="form-inline">
				<div class="form-group">
					<select class="form-control" ng-model="customer">
						<option value="common">普通客户</option>
						<option value="member"> 会 员 </option>
					</select>
				</div>
				<div class="form-group">
					<label>会员号</label>
					<input type="text" class="form-control" ng-model="customerNo" ng-disabled="customer==='common'">
				</div>
				<div class="form-group">
					<label>条形码</label>
					<input type="text" class="form-control" ng-model="barcode" placeholder="6936983800013">
				</div>
				<div class="form-group">
					<label>数量</label>
					<input type="number" class="form-control" ng-model="quantity">
				</div>
				<button type="button" class="btn btn-primary" ng-click="addItem()"> 添 加 <i class="fa fa-plus-circle fa-lg"></i></button>
			</form>
		</section>
		<section class="salesGoods table-responsive">
			<table class="table table-bordered table-hover">
				<tr>
					<th>#</th>
					<th>条形码</th>
					<th>名称</th>
					<th>单价</th>
					<th>数量</th>
					<th>金额</th>
				</tr>
				<tr ng-repeat="item in selectedItem">
					<td>{{$index+1}}</td>
					<td>{{item.barcode}}</td>
					<td>{{item.name}}</td>
					<td>{{item.salePrice}}</td>
					<td>{{item.quantity}}</td>
					<td>{{item.subTotal}}</td>
				</tr>
			</table>
		</section>
		<section class="info">
			<form class="form-inline">
				<div class="form-group">
					<select class="form-control" ng-model="payType">
						<option value="1">现 金</option>
						<option value="2">微 信</option>
						<option value="3">支付宝</option>
						<option value="4">银行卡</option>
					</select>
				</div>
				<div class="form-group">
					<label>备注</label>
					<input type="text" class="form-control" ng-model="remark">
				</div>
			</form>
		</section>
		<section class="settlement">
			<span>合计：</span><span>{{total}}</span><span>￥</span>
			<form class="form-inline">
				<div class="form-group">
					<label>收款金额：</label>
					<input type="number" class="form-control" ng-model="receivablesAmount">
				</div>
				<div class="form-group">
					<button type="button" class="btn btn-info" ng-click="balance()" ng-disabled="balanceFlag">结 算</button>
				</div>
			</form>
			<form class="form-inline">
				<div class="form-group">
					<label>找款金额：</label>
					<input type="number" class="form-control" ng-model="returnAmount">
				</div>
			</form>
			<button type="button" class="btn btn-danger" ng-click="cancle()" ng-disabled="balanceFlag">取 消</button>
			<button type="button" class="btn btn-success" ng-click="completed()" ng-disabled="!balanceFlag">交易完成</button>
		</section>
	</div>
</div>